package com.lxh.lxhcrm.model.pojos;

import javax.persistence.*;
import java.util.Objects;

/**
 * 支付方式
 */
@Entity
@Table(name="pay_wey",schema = "lxh_crm", catalog = "")
public class PayWey {
    private int payId;
    private String payName;

    @Id
    @Column(name = "pay_id", nullable = false)
    public int getPayId() {
        return payId;
    }

    public void setPayId(int payId) {
        this.payId = payId;
    }

    @Basic
    @Column(name = "pay_name", nullable = true, length = 40)
    public String getPayName() {
        return payName;
    }

    public void setPayName(String payName) {
        this.payName = payName;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        PayWey payWey = (PayWey) o;
        return payId == payWey.payId &&
                Objects.equals(payName, payWey.payName);
    }

    @Override
    public int hashCode() {
        return Objects.hash(payId, payName);
    }
}
